import Vue from 'vue'
import Vuex from 'vuex'

Vue.use(Vuex)

const store = new Vuex.Store({
  state: {
    coverUpload: {},
    coverOneUpload: {},
    avatarUpload: {},
    avatarOneUpload: {},
    payUpload: {},
    pictureUpload: {},
    pictureOneUpload: {},
    videoOneUpload: {},
    coverUrl: '',
    avatarUrl: '',
    pictureUrl: '',
    pictureOneUrl: '',
    avatarOneUrl: '',
    timeFun: '',
    payUrl: '',
    requestUrls: '',
    uploadStatus: false,
    initDataFlag: true,
    uploadShow: false,//也用在了视频上传
    uploadLimit: 2,
    uploadPath: '',
    coverOneUrl: '',
    fileList: [],
    ossUpload: [],
    ossVideoCoverTemp: [],
    ossVideoCover: [],
    ossUploading: [],
    detailsUploadList: [],
    detailsContentList: [],
    videoFileList: [],
    detailsVideoList: [
      {
        videoCover: ''
      }
    ],
    mp3FileUploadList: [],
    coverUploadList: [],
    videoListUpload: [],
    unitList: [
      {
        value: '米',
        label: '米'
      },
      {
        value: '㎡',
        label: '㎡'
      },
      {
        value: '套',
        label: '套'
      }
    ]
  },
  mutations: {
    //
    setOssUpload(state, ossUpload) {
      state.ossUpload = ossUpload
    }

  }
})

export default store
